/*
 * ==============================================================================
 Name		: MusicInterceptAppView.h
 Author		:  
 Copyrigh	: Your copyright notice
 Description	: Declares view class for application.
 * ==============================================================================
 */

#ifndef __MUSICINTERCEPT_VIEW2_H__
#define __MUSICINTERCEPT_VIEW2_H__

// INCLUDES
#include <aknview.h>

// FORWARD DECLARATIONS
class CMusicInterceptContainer2;

// CLASS DECLARATION

/**
 * CMusicInterceptView2 view class.
 * An instance of the Application View object for the 
 * application
 */
class CMusicInterceptView2 : public CAknView
	{
public:
	// Constructors and destructor

	/**
	 * NewL.
	 * Two-phased constructor.
	 * Construct a CMusicInterceptView1 for the AVKON application aApp.
	 * Using two phase construction,and return a pointer to the created object.
	 * @return a pointer to the created instance of CMusicInterceptView2
	 */
	static CMusicInterceptView2* NewL();

	/**
	 * NewLC.
	 * Two-phased constructor.
	 * Construct a CMusicInterceptView2 for the AVKON application aApp.
	 * Using two phase construction,and return a pointer to the created object.
	 * @return a pointer to the created instance of CMusicInterceptView2
	 */
	static CMusicInterceptView2* NewLC();

	/**
	 * ~CMusicInterceptView2.
	 * Virtual Destructor.
	 */
	virtual ~CMusicInterceptView2();

public:
	// Functions from base classes from CAknView

	/**
	 * Id
	 * From CAknView, return Uid.
	 * @return Uid Uid value
	 */
	TUid Id() const;

	/**
	 * HandleCommandL
	 * From CAknView, takes care of command handling.
	 * @param aCommand Command to be handled
	 */
	void HandleCommandL(TInt aCommand);

	/**
	 * DoActivateL
	 * From CAknExView, activate an AknView.
	 * @param aPrevViewId The id of the previous view
	 * @param aCustomMessageId message identifier
	 * @param aCustomMessage custom message provided when the view is changed
	 */
	void DoActivateL(const TVwsViewId& aPrevViewId, TUid aCustomMessageId,
			const TDesC8& aCustomMessage);

	/**
	 * DoDeactivate
	 * From AknView, deactivate an AknView
	 * Remove the container class instance from the App UI's stack and
	 * deletes the instance
	 */
	void DoDeactivate();

	/**
	 * HandleSizeChange
	 * Called by HandleResourceChangeL() from CMultiViewsAppUi when layout 
	 * is changed.
	 * @param aType Type of resources that have changed
	 */
	void HandleSizeChange(TInt aType);

private:
	// Constructors and destructor

	/**
	 * CMusicInterceptView2.
	 * C++ default constructor.
	 */
	CMusicInterceptView2();

	/**
	 * ConstructL.
	 * 2nd phase constructor.
	 */
	void ConstructL();

private:
	// Data

	/**
	 * iContainer,container for this view
	 * owned by CMusicInterceptView2 object.
	 */
	CMusicInterceptContainer2* iContainer;

	/** View Identifier **/
	TUid iIdentifier;
	};

#endif // __MUSICINTERCEPT_VIEW2_H__

// End of File